projects
/
project
/
bcm63xx
/
u-boot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
117029c
)
sh: timer: Remove unnecessary variable 'ticks'
author
Nobuhiro Iwamatsu
<
[email protected]
>
Thu, 1 Mar 2012 04:29:38 +0000
(13:29 +0900)
committer
Nobuhiro Iwamatsu
<
[email protected]
>
Thu, 8 Mar 2012 01:26:38 +0000
(10:26 +0900)
Signed-off-by: Nobuhiro Iwamatsu <
[email protected]
>
Reported-by: Mike Frysinger <
[email protected]
>
Signed-off-by: Nobuhiro Iwamatsu <
[email protected]
>
arch/sh/lib/time.c
patch
|
blob
|
history
diff --git
a/arch/sh/lib/time.c
b/arch/sh/lib/time.c
index c70baedbf1cac8e87f70b0019ce51b35c7c58a7e..a01596cace6eb2bb477b9fbb7e224a9f90239ee9 100644
(file)
--- a/
arch/sh/lib/time.c
+++ b/
arch/sh/lib/time.c
@@
-108,14
+108,9
@@
int timer_init (void)
unsigned long long get_ticks (void)
{
unsigned long tcnt = 0 - readl(TCNT0);
- unsigned long ticks;
- if (last_tcnt > tcnt)
{
/* overflow */
+ if (last_tcnt > tcnt) /* overflow */
overflow_ticks++;
- ticks = (0xffffffff - last_tcnt) + tcnt;
- } else {
- ticks = tcnt;
- }
last_tcnt = tcnt;
return (overflow_ticks << 32) | tcnt;